<template>
	<list-scroll class="list-scroll" @loadmore = "loadmore">
		<list-card mode="base" :item="item" v-for="(item,index) in list" :key="item._id"></list-card>
		
		<uni-load-more v-if="list.length == 0 || list.length >4" iconType="snow" status="load.loading"></uni-load-more>
		
		
		<!-- <list-card mode="image"></list-card>
		<list-card mode="column"></list-card>
		<list-card mode="base"></list-card>
		<list-card mode="image"></list-card>
		<list-card mode="column"></list-card>
		<list-card mode="base"></list-card>
		<list-card mode="image"></list-card>
		<list-card mode="column"></list-card> -->
	</list-scroll>
</template>

<script>
	export default {
		name:"list-item",
		props:{
				list:{
					type:Array,
					default() {
						return []
					}
				},
				load:{
					type:Object,
					default() {
						return {
							loading: "loading"
						}
					}
				}
		},
		data() {
			return {
				
			};
		},
		methods:{
			loadmore() {
				this.$emit('loadmore')
			}
		}
	}
</script>

<style>
	.list-scroll{
		height: 100%;
	}
</style>
